package com.jmlee.service;



import com.jmlee.pojo.AShop;
import com.jmlee.pojo.Admin;
import com.jmlee.pojo.LoginTicket;
import org.apache.ibatis.session.RowBounds;

import java.util.List;
import java.util.Map;

/**
 * @Description 后台用户 Service
 * @Author jmLee
 * @Date 2021/3/3 12:55
 * @Version 1.0
 */
public interface AdminService {


    Map<String, Object> login(String username, String password, int expiredSeconds);
//=================================================================================================================
    /**
     *后台用户
     * @param admin
     * @return
     */
    int selectAdminListCount(Admin admin);

    List<Admin> selectAdminList(Admin admin, RowBounds rowBounds);
    List<Admin> getUserInfoList(Admin admin);

//    //       新增
//    boolean addAdmin(Admin admin);
    /**
     * 新增人员
     * @return
     */
    Boolean addNewUserInfo(Admin admin);

    /**
     * 新增商家
     * @param aShop
     * @return
     */
    int insertShop(AShop aShop);
    //       删除
    boolean delete(Admin admin);

    //修改提交
    Integer updateAdminSubmit(Admin admin);

    /**
     * 根据id查询用户信息
     */

    Admin queryAdminById(Long id);

    //查询用户名是否重复
    Admin checkName(String username);

//====================================================================
    LoginTicket findLoginTicket(String ticket);

    Admin findAdminById(Long userId);

    void logout(String ticket);


    /**
     * 插入图片
     */
    Integer addAdminImage(Admin admin);


}
